#pragma once

class CLockCS
{
public:
	//##ModelId=44C4B5F70233
	CLockCS(void)
	{
		InitializeCriticalSection( &m_csAccess );
	}
	//##ModelId=44C4B5F70235
	virtual ~CLockCS(void)
	{
		DeleteCriticalSection( &m_csAccess );
	}
	//##ModelId=44C4B5F70238
	virtual void Lock()
	{
		EnterCriticalSection( &m_csAccess );
	}
	//##ModelId=44C4B5F70243
	virtual void Unlock()
	{
		LeaveCriticalSection( &m_csAccess );
	}
protected:
	//##ModelId=44C4B5F70245
	CRITICAL_SECTION	m_csAccess;
};
